#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>

struct ListNode {
    int val;
    struct ListNode* next;
};
struct ListNode* reverseList(struct ListNode* head) {
    struct ListNode* newhead = NULL;
    struct ListNode* cur = head;
    struct ListNode* next = NULL;
    while (cur != NULL)
    {
        next = cur->next;
        cur->next = newhead;
        newhead = cur;
    }
    return newhead;
}
int main()
{
    struct ListNode *n1 = reverseList()
    return 0;
}
